import { createRouter, createWebHistory } from 'vue-router'
import HomeView from '../views/HomeView.vue'

const router = createRouter({
  history: createWebHistory(import.meta.env.BASE_URL),
  routes: [
    {
      path: '/',
      name: 'home',
      component: HomeView,
    },
    {
      path: '/map/:id',
      component: HomeView,
    },
    {
      path: '/map-manage',
      name: '/map-manage',
      component: () => import('../views/mapManage/MapManage.vue'),
    },
    {
      path: '/map-manage/name/:id',
      name: 'name',
      component: () => import('../views/mapManage/PlacenameManage.vue'),
    },
    {
      path: '/map-manage/point/:id',
      name: 'point',
      component: () => import('../views/mapManage/PointManage.vue'),
    },
    {
      path: '/map-manage/line/:id',
      name: 'line',
      component: () => import('../views/mapManage/LineManage.vue'),
    },
    {
      path: '/map-manage/setting',
      name: 'setting',
      component: () => import('../views/mapManage/SettingView.vue'),
    },
  ],
})

export default router
